

//页面状态相关
let status = {
};

// 和网络交互相关的参数
let params = {
  searchParams:{
    startDate : "",
    endDate : ""
  }
};

// 页面的数据源
let data = {
  userAnalysisList: [],
};

// 页码相关
let page = {
  total: 1,
  startIndex: 0,
  stepNumber: 60,
  currentPage: 1
};

//列表
let userAnalysisTable=function (self) {
  return [
    {
      title: '日期',
      width: 130,
      key: 'date',
      align:'center',
      render: (h, params) => {
        let date = new Date(params.row.date);
        return h('div', self.$tiyBJTime(params.row.date));
      }
    },
    {
      title: '登录次数',
      width: 120,
      key: 'loginNumber',
      align:'center'
    },
    {
      title: '登录用户数',
      width: 120,
      key: 'loginUser',
      align:'center'
    },
    {
      title: '加购次数',
      width: 120,
      key: 'addCartNumber',
      align:'center'
    },
    {
      title: '加购用户数',
      width: 120,
      key: 'addCartUser',
      align:'center'
    },
    {
      title: '购物车金额',
      width: 120,
      key: 'cartAmount',
      align:'center'
    },
    {
      title: '下单笔数',
      width: 120,
      key: 'orderNumber',
      align:'center'
    },
    {
      title: '下单用户数',
      width: 120,
      key: 'orderUser',
      align:'center'
    },
    {
      title: '转换率',
      width: 120,
      key: 'p',
      align:'center'
    },
    {
      title: '当日销售额',
      width: 120,
      key: 'sumOrder',
      align:'center'
    }
  ];
};

export  default  {
  tStatus: status,
  tParams: params,
  tData: data,
  tPage: page,
  userAnalysisTable:userAnalysisTable,
};
